﻿using System;
using System.Collections.Generic;
using System.Text;
using Ghasam.Business.Domain.Entity;
using Ghasam.Business.DAO;
using Spring.Transaction.Interceptor;

namespace Ghasam.Business.Services.Impl {
    
    public class BasicSalaryService : IBasicSalaryService {

        public IBasicSalaryDao BasicSalaryDao { get; set; }


        #region IBasicSalaryService Members

        public BasicSalary GetEmployeeSalaryInfo(Employee employee) {
            return BasicSalaryDao.FindById(employee.Id);
        }

        [Transaction(ReadOnly=false)]
        public BasicSalary Save(BasicSalary basicSalary) {
            return BasicSalaryDao.SaveOrUpdate(basicSalary);
        }

        public BasicSalary GetSalary(int Id) {
            return BasicSalaryDao.FindById(Id);
        }

        #endregion
    }
}
